package jdmx.framework.ui;

import java.io.File;
import java.io.IOException;
import org.jdom.Document;
import org.jdom.Element;
import org.jdom.JDOMException;
import org.jdom.input.SAXBuilder;

public class UIConfiguration {	
	public String proxyType = null;

	public void readLocalConfiguration() {
		String fileName = "./conf/uiconfig.xml";
		File file = new File(fileName);
		SAXBuilder parser = new SAXBuilder();
		Document xmlDocument = null;
		try {
			xmlDocument = parser.build(file);
		} catch (JDOMException e1) {
		} catch (IOException e1) {
		}
		if (xmlDocument == null) return;
		
		Element rootElement = xmlDocument.getRootElement();
		if (rootElement.getChild("proxyType") != null)
			proxyType = rootElement.getChild("proxyType").getText();
	}
}
